package com.vinku.app;

import com.vinku.app.entity.User;
import com.vinku.app.service.UserService;

import java.util.concurrent.TimeUnit;

/**
 * @Author Vinku
 * @Date 2022/10/21
 * @Description
 */
public class AppController {

    public static void main(String[] args) throws InterruptedException {
        System.out.println("AppController main 执行！！！！！！！！！！！！！！！");
        test1();
//        test2();
    }

    private static void test1() throws InterruptedException {
        TimeUnit.MILLISECONDS.sleep(1000);
        User user = new User();
        System.out.println(user);
        UserService service = new UserService();
        System.out.println(service.sayHello());
        service.sleepRandom();
        service.sleepRandom();
    }


//    private static void test2() throws InterruptedException {
//        while (true) {
//            UserService service = new UserService();
//            service.sayHello();
//            TimeUnit.MILLISECONDS.sleep(1000);
//        }
//    }

}
